{
 "cells": [
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "# Standard Type Library"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Pandapower provides a standard type library that allows the comfortable managing of type data for lines and transformers.\n",
    "\n",
    "The following examples are all based on lines, but can be equally used for the transformer database by specifying element=\"trafo\" instead of element=\"line\" in all standard type functions."
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Basic Pandapower Standard Types"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Pandapower comes with generic standard types that you can use to build generic networks:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {
    "scrolled": true
   },
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>alpha</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>q_mm2</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>type</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>NAYY 4x50 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>210.00</td>\n",
       "      <td>0.142</td>\n",
       "      <td>50</td>\n",
       "      <td>0.6420</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x120 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>264.00</td>\n",
       "      <td>0.242</td>\n",
       "      <td>120</td>\n",
       "      <td>0.2250</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x150 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>261.00</td>\n",
       "      <td>0.270</td>\n",
       "      <td>150</td>\n",
       "      <td>0.2080</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>216.00</td>\n",
       "      <td>0.252</td>\n",
       "      <td>95</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>273.00</td>\n",
       "      <td>0.362</td>\n",
       "      <td>185</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.117</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>304.00</td>\n",
       "      <td>0.421</td>\n",
       "      <td>240</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>315.00</td>\n",
       "      <td>0.249</td>\n",
       "      <td>95</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>406.00</td>\n",
       "      <td>0.358</td>\n",
       "      <td>185</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>456.00</td>\n",
       "      <td>0.416</td>\n",
       "      <td>240</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.105</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>250.00</td>\n",
       "      <td>0.319</td>\n",
       "      <td>150</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.116</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>230.00</td>\n",
       "      <td>0.283</td>\n",
       "      <td>120</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.119</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>190.00</td>\n",
       "      <td>0.220</td>\n",
       "      <td>70</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>360.00</td>\n",
       "      <td>0.315</td>\n",
       "      <td>150</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>340.00</td>\n",
       "      <td>0.280</td>\n",
       "      <td>120</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>280.00</td>\n",
       "      <td>0.217</td>\n",
       "      <td>70</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x120 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>112.00</td>\n",
       "      <td>0.366</td>\n",
       "      <td>120</td>\n",
       "      <td>0.1530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.166</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x185 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>125.00</td>\n",
       "      <td>0.457</td>\n",
       "      <td>185</td>\n",
       "      <td>0.0990</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.156</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x240 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>135.00</td>\n",
       "      <td>0.526</td>\n",
       "      <td>240</td>\n",
       "      <td>0.0750</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x300 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>144.00</td>\n",
       "      <td>0.588</td>\n",
       "      <td>300</td>\n",
       "      <td>0.0600</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.144</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15-AL1/3-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.105</td>\n",
       "      <td>16</td>\n",
       "      <td>1.8769</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24-AL1/4-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.140</td>\n",
       "      <td>24</td>\n",
       "      <td>1.2012</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.335</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>12.20</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.300</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>13.20</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.290</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.10</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.40</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.10</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.323</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.315</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.15</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.382</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.50</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.372</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.30</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.50</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.337</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.320</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.75</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.410</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.80</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.400</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>305-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.20</td>\n",
       "      <td>0.740</td>\n",
       "      <td>305</td>\n",
       "      <td>0.0949</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 220.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.285</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 380.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.253</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                    alpha  c_nf_per_km  max_i_ka  q_mm2  \\\n",
       "NAYY 4x50 SE                      0.00403       210.00     0.142     50   \n",
       "NAYY 4x120 SE                     0.00403       264.00     0.242    120   \n",
       "NAYY 4x150 SE                     0.00403       261.00     0.270    150   \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV       0.00403       216.00     0.252     95   \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      0.00403       273.00     0.362    185   \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      0.00403       304.00     0.421    240   \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV        0.00403       315.00     0.249     95   \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       0.00403       406.00     0.358    185   \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       0.00403       456.00     0.416    240   \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      0.00403       250.00     0.319    150   \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      0.00403       230.00     0.283    120   \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV       0.00403       190.00     0.220     70   \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       0.00403       360.00     0.315    150   \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       0.00403       340.00     0.280    120   \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV        0.00403       280.00     0.217     70   \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  0.00393       112.00     0.366    120   \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  0.00393       125.00     0.457    185   \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  0.00393       135.00     0.526    240   \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  0.00393       144.00     0.588    300   \n",
       "15-AL1/3-ST1A 0.4                 0.00403        11.00     0.105     16   \n",
       "24-AL1/4-ST1A 0.4                 0.00403        11.25     0.140     24   \n",
       "48-AL1/8-ST1A 0.4                 0.00403        12.20     0.210     48   \n",
       "94-AL1/15-ST1A 0.4                0.00403        13.20     0.350     94   \n",
       "34-AL1/6-ST1A 10.0                0.00403         9.70     0.170     34   \n",
       "48-AL1/8-ST1A 10.0                0.00403        10.10     0.210     48   \n",
       "70-AL1/11-ST1A 10.0               0.00403        10.40     0.290     70   \n",
       "94-AL1/15-ST1A 10.0               0.00403        10.75     0.350     94   \n",
       "122-AL1/20-ST1A 10.0              0.00403        11.10     0.410    122   \n",
       "149-AL1/24-ST1A 10.0              0.00403        11.25     0.470    149   \n",
       "34-AL1/6-ST1A 20.0                0.00403         9.15     0.170     34   \n",
       "48-AL1/8-ST1A 20.0                0.00403         9.50     0.210     48   \n",
       "70-AL1/11-ST1A 20.0               0.00403         9.70     0.290     70   \n",
       "94-AL1/15-ST1A 20.0               0.00403        10.00     0.350     94   \n",
       "122-AL1/20-ST1A 20.0              0.00403        10.30     0.410    122   \n",
       "149-AL1/24-ST1A 20.0              0.00403        10.50     0.470    149   \n",
       "184-AL1/30-ST1A 20.0              0.00403        10.75     0.535    184   \n",
       "243-AL1/39-ST1A 20.0              0.00403        11.00     0.645    243   \n",
       "149-AL1/24-ST1A 110.0             0.00403         8.75     0.470    149   \n",
       "184-AL1/30-ST1A 110.0             0.00403         8.80     0.535    184   \n",
       "243-AL1/39-ST1A 110.0             0.00403         9.00     0.645    243   \n",
       "305-AL1/39-ST1A 110.0             0.00403         9.20     0.740    305   \n",
       "490-AL1/64-ST1A 220.0             0.00403        10.00     0.960    490   \n",
       "490-AL1/64-ST1A 380.0             0.00403        11.00     0.960    490   \n",
       "\n",
       "                                  r_ohm_per_km type  x_ohm_per_km  \n",
       "NAYY 4x50 SE                            0.6420   cs         0.083  \n",
       "NAYY 4x120 SE                           0.2250   cs         0.080  \n",
       "NAYY 4x150 SE                           0.2080   cs         0.080  \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV             0.3130   cs         0.132  \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV            0.1610   cs         0.117  \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV            0.1220   cs         0.112  \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV              0.3130   cs         0.123  \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV             0.1610   cs         0.110  \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV             0.1220   cs         0.105  \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV            0.2060   cs         0.116  \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV            0.2530   cs         0.119  \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV             0.4430   cs         0.132  \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV             0.2060   cs         0.110  \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV             0.2530   cs         0.113  \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV              0.4430   cs         0.123  \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV        0.1530   cs         0.166  \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV        0.0990   cs         0.156  \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV        0.0750   cs         0.149  \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV        0.0600   cs         0.144  \n",
       "15-AL1/3-ST1A 0.4                       1.8769   ol         0.350  \n",
       "24-AL1/4-ST1A 0.4                       1.2012   ol         0.335  \n",
       "48-AL1/8-ST1A 0.4                       0.5939   ol         0.300  \n",
       "94-AL1/15-ST1A 0.4                      0.3060   ol         0.290  \n",
       "34-AL1/6-ST1A 10.0                      0.8342   ol         0.360  \n",
       "48-AL1/8-ST1A 10.0                      0.5939   ol         0.350  \n",
       "70-AL1/11-ST1A 10.0                     0.4132   ol         0.339  \n",
       "94-AL1/15-ST1A 10.0                     0.3060   ol         0.330  \n",
       "122-AL1/20-ST1A 10.0                    0.2376   ol         0.323  \n",
       "149-AL1/24-ST1A 10.0                    0.1940   ol         0.315  \n",
       "34-AL1/6-ST1A 20.0                      0.8342   ol         0.382  \n",
       "48-AL1/8-ST1A 20.0                      0.5939   ol         0.372  \n",
       "70-AL1/11-ST1A 20.0                     0.4132   ol         0.360  \n",
       "94-AL1/15-ST1A 20.0                     0.3060   ol         0.350  \n",
       "122-AL1/20-ST1A 20.0                    0.2376   ol         0.344  \n",
       "149-AL1/24-ST1A 20.0                    0.1940   ol         0.337  \n",
       "184-AL1/30-ST1A 20.0                    0.1571   ol         0.330  \n",
       "243-AL1/39-ST1A 20.0                    0.1188   ol         0.320  \n",
       "149-AL1/24-ST1A 110.0                   0.1940   ol         0.410  \n",
       "184-AL1/30-ST1A 110.0                   0.1571   ol         0.400  \n",
       "243-AL1/39-ST1A 110.0                   0.1188   ol         0.390  \n",
       "305-AL1/39-ST1A 110.0                   0.0949   ol         0.380  \n",
       "490-AL1/64-ST1A 220.0                   0.0590   ol         0.285  \n",
       "490-AL1/64-ST1A 380.0                   0.0590   ol         0.253  "
      ]
     },
     "execution_count": 1,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandapower as pp\n",
    "net = pp.create_empty_network()\n",
    "pp.available_std_types(net, element=\"line\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "If you create a line with the create_line function, the element parameters are taken from this library:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 2,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "name               test_line\n",
       "std_type        NAYY 4x50 SE\n",
       "from_bus                   0\n",
       "to_bus                     1\n",
       "length_km                0.1\n",
       "r_ohm_per_km           0.642\n",
       "x_ohm_per_km           0.083\n",
       "c_nf_per_km              210\n",
       "g_us_per_km                0\n",
       "max_i_ka               0.142\n",
       "df                         1\n",
       "parallel                   1\n",
       "type                      cs\n",
       "in_service              True\n",
       "Name: 0, dtype: object"
      ]
     },
     "execution_count": 2,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "b1 = pp.create_bus(net, vn_kv=.4)\n",
    "b2 = pp.create_bus(net, vn_kv=.4)\n",
    "lid = pp.create_line(net, from_bus=b1, to_bus=b2, length_km=0.1, std_type=\"NAYY 4x50 SE\", name=\"test_line\")\n",
    "net.line.loc[lid]"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Create Individual Standard Types"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Additionally to the basic pandapower standard types, you can define individual standard types for you pandapower network.\n",
    "\n",
    "To create a new standard type you need at least the following parameters:\n",
    "\n",
    "**For Lines**:\n",
    "- r_ohm_per_km\n",
    "- x_ohm_per_km\n",
    "- c_nf_per_km\n",
    "- max_i_ka\n",
    "\n",
    "**For Transformers:**\n",
    "- sn_mva\n",
    "- vn_hv_kv\n",
    "- vn_lv_kv\n",
    "- vk_percent\n",
    "- vkr_percent\n",
    "- i0_percent\n",
    "- pfe_kw\n",
    "- shift_degree\n",
    "\n",
    "To define the parameters, create a dictionary with the style {\"parameter1\": parameter_value1, \"parameter2\": paramter_value2,...} and save the standard type to your network with the create_std_type function:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 4,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>alpha</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>q_mm2</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>type</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>NAYY 4x50 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>210.00</td>\n",
       "      <td>0.142</td>\n",
       "      <td>50.0</td>\n",
       "      <td>0.6420</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x120 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>264.00</td>\n",
       "      <td>0.242</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2250</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x150 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>261.00</td>\n",
       "      <td>0.270</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2080</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>216.00</td>\n",
       "      <td>0.252</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>273.00</td>\n",
       "      <td>0.362</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.117</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>304.00</td>\n",
       "      <td>0.421</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>315.00</td>\n",
       "      <td>0.249</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>406.00</td>\n",
       "      <td>0.358</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>456.00</td>\n",
       "      <td>0.416</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.105</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>250.00</td>\n",
       "      <td>0.319</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.116</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>230.00</td>\n",
       "      <td>0.283</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.119</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>190.00</td>\n",
       "      <td>0.220</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>360.00</td>\n",
       "      <td>0.315</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>340.00</td>\n",
       "      <td>0.280</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>280.00</td>\n",
       "      <td>0.217</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x120 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>112.00</td>\n",
       "      <td>0.366</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.1530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.166</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x185 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>125.00</td>\n",
       "      <td>0.457</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.0990</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.156</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x240 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>135.00</td>\n",
       "      <td>0.526</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.0750</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x300 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>144.00</td>\n",
       "      <td>0.588</td>\n",
       "      <td>300.0</td>\n",
       "      <td>0.0600</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.144</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15-AL1/3-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.105</td>\n",
       "      <td>16.0</td>\n",
       "      <td>1.8769</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24-AL1/4-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.140</td>\n",
       "      <td>24.0</td>\n",
       "      <td>1.2012</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.335</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>12.20</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.300</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>13.20</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.290</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.10</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.40</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.10</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.323</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.315</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.15</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.382</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.50</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.372</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.30</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.50</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.337</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.320</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.75</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.410</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.80</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.400</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>305-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.20</td>\n",
       "      <td>0.740</td>\n",
       "      <td>305.0</td>\n",
       "      <td>0.0949</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 220.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.285</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 380.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>test_type</th>\n",
       "      <td>NaN</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.400</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0100</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.020</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                    alpha  c_nf_per_km  max_i_ka  q_mm2  \\\n",
       "NAYY 4x50 SE                      0.00403       210.00     0.142   50.0   \n",
       "NAYY 4x120 SE                     0.00403       264.00     0.242  120.0   \n",
       "NAYY 4x150 SE                     0.00403       261.00     0.270  150.0   \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV       0.00403       216.00     0.252   95.0   \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      0.00403       273.00     0.362  185.0   \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      0.00403       304.00     0.421  240.0   \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV        0.00403       315.00     0.249   95.0   \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       0.00403       406.00     0.358  185.0   \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       0.00403       456.00     0.416  240.0   \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      0.00403       250.00     0.319  150.0   \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      0.00403       230.00     0.283  120.0   \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV       0.00403       190.00     0.220   70.0   \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       0.00403       360.00     0.315  150.0   \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       0.00403       340.00     0.280  120.0   \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV        0.00403       280.00     0.217   70.0   \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  0.00393       112.00     0.366  120.0   \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  0.00393       125.00     0.457  185.0   \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  0.00393       135.00     0.526  240.0   \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  0.00393       144.00     0.588  300.0   \n",
       "15-AL1/3-ST1A 0.4                 0.00403        11.00     0.105   16.0   \n",
       "24-AL1/4-ST1A 0.4                 0.00403        11.25     0.140   24.0   \n",
       "48-AL1/8-ST1A 0.4                 0.00403        12.20     0.210   48.0   \n",
       "94-AL1/15-ST1A 0.4                0.00403        13.20     0.350   94.0   \n",
       "34-AL1/6-ST1A 10.0                0.00403         9.70     0.170   34.0   \n",
       "48-AL1/8-ST1A 10.0                0.00403        10.10     0.210   48.0   \n",
       "70-AL1/11-ST1A 10.0               0.00403        10.40     0.290   70.0   \n",
       "94-AL1/15-ST1A 10.0               0.00403        10.75     0.350   94.0   \n",
       "122-AL1/20-ST1A 10.0              0.00403        11.10     0.410  122.0   \n",
       "149-AL1/24-ST1A 10.0              0.00403        11.25     0.470  149.0   \n",
       "34-AL1/6-ST1A 20.0                0.00403         9.15     0.170   34.0   \n",
       "48-AL1/8-ST1A 20.0                0.00403         9.50     0.210   48.0   \n",
       "70-AL1/11-ST1A 20.0               0.00403         9.70     0.290   70.0   \n",
       "94-AL1/15-ST1A 20.0               0.00403        10.00     0.350   94.0   \n",
       "122-AL1/20-ST1A 20.0              0.00403        10.30     0.410  122.0   \n",
       "149-AL1/24-ST1A 20.0              0.00403        10.50     0.470  149.0   \n",
       "184-AL1/30-ST1A 20.0              0.00403        10.75     0.535  184.0   \n",
       "243-AL1/39-ST1A 20.0              0.00403        11.00     0.645  243.0   \n",
       "149-AL1/24-ST1A 110.0             0.00403         8.75     0.470  149.0   \n",
       "184-AL1/30-ST1A 110.0             0.00403         8.80     0.535  184.0   \n",
       "243-AL1/39-ST1A 110.0             0.00403         9.00     0.645  243.0   \n",
       "305-AL1/39-ST1A 110.0             0.00403         9.20     0.740  305.0   \n",
       "490-AL1/64-ST1A 220.0             0.00403        10.00     0.960  490.0   \n",
       "490-AL1/64-ST1A 380.0             0.00403        11.00     0.960  490.0   \n",
       "test_type                             NaN        10.00     0.400    NaN   \n",
       "\n",
       "                                  r_ohm_per_km type  x_ohm_per_km  \n",
       "NAYY 4x50 SE                            0.6420   cs         0.083  \n",
       "NAYY 4x120 SE                           0.2250   cs         0.080  \n",
       "NAYY 4x150 SE                           0.2080   cs         0.080  \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV             0.3130   cs         0.132  \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV            0.1610   cs         0.117  \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV            0.1220   cs         0.112  \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV              0.3130   cs         0.123  \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV             0.1610   cs         0.110  \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV             0.1220   cs         0.105  \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV            0.2060   cs         0.116  \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV            0.2530   cs         0.119  \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV             0.4430   cs         0.132  \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV             0.2060   cs         0.110  \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV             0.2530   cs         0.113  \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV              0.4430   cs         0.123  \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV        0.1530   cs         0.166  \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV        0.0990   cs         0.156  \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV        0.0750   cs         0.149  \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV        0.0600   cs         0.144  \n",
       "15-AL1/3-ST1A 0.4                       1.8769   ol         0.350  \n",
       "24-AL1/4-ST1A 0.4                       1.2012   ol         0.335  \n",
       "48-AL1/8-ST1A 0.4                       0.5939   ol         0.300  \n",
       "94-AL1/15-ST1A 0.4                      0.3060   ol         0.290  \n",
       "34-AL1/6-ST1A 10.0                      0.8342   ol         0.360  \n",
       "48-AL1/8-ST1A 10.0                      0.5939   ol         0.350  \n",
       "70-AL1/11-ST1A 10.0                     0.4132   ol         0.339  \n",
       "94-AL1/15-ST1A 10.0                     0.3060   ol         0.330  \n",
       "122-AL1/20-ST1A 10.0                    0.2376   ol         0.323  \n",
       "149-AL1/24-ST1A 10.0                    0.1940   ol         0.315  \n",
       "34-AL1/6-ST1A 20.0                      0.8342   ol         0.382  \n",
       "48-AL1/8-ST1A 20.0                      0.5939   ol         0.372  \n",
       "70-AL1/11-ST1A 20.0                     0.4132   ol         0.360  \n",
       "94-AL1/15-ST1A 20.0                     0.3060   ol         0.350  \n",
       "122-AL1/20-ST1A 20.0                    0.2376   ol         0.344  \n",
       "149-AL1/24-ST1A 20.0                    0.1940   ol         0.337  \n",
       "184-AL1/30-ST1A 20.0                    0.1571   ol         0.330  \n",
       "243-AL1/39-ST1A 20.0                    0.1188   ol         0.320  \n",
       "149-AL1/24-ST1A 110.0                   0.1940   ol         0.410  \n",
       "184-AL1/30-ST1A 110.0                   0.1571   ol         0.400  \n",
       "243-AL1/39-ST1A 110.0                   0.1188   ol         0.390  \n",
       "305-AL1/39-ST1A 110.0                   0.0949   ol         0.380  \n",
       "490-AL1/64-ST1A 220.0                   0.0590   ol         0.285  \n",
       "490-AL1/64-ST1A 380.0                   0.0590   ol         0.253  \n",
       "test_type                               0.0100   cs         0.020  "
      ]
     },
     "execution_count": 4,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "net = pp.create_empty_network()\n",
    "test_type = {\"r_ohm_per_km\": 0.01, \"x_ohm_per_km\": 0.02, \"c_nf_per_km\": 10, \"max_i_ka\": 0.4, \"type\": \"cs\"}\n",
    "pp.create_std_type(net, name=\"test_type\", data=test_type, element=\"line\")\n",
    "pp.available_std_types(net, element=\"line\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "As you can see the test_type is now available in the standard type library, and you can use it to create a line:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 5,
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "name            test_line\n",
      "std_type        test_type\n",
      "from_bus                0\n",
      "to_bus                  1\n",
      "length_km             0.1\n",
      "r_ohm_per_km         0.01\n",
      "x_ohm_per_km         0.02\n",
      "c_nf_per_km            10\n",
      "g_us_per_km             0\n",
      "max_i_ka              0.4\n",
      "df                      1\n",
      "parallel                1\n",
      "type                   cs\n",
      "in_service           True\n",
      "Name: 0, dtype: object\n"
     ]
    }
   ],
   "source": [
    "b1 = pp.create_bus(net, vn_kv=.4)\n",
    "b2 = pp.create_bus(net, vn_kv=.4)\n",
    "lid = pp.create_line(net, from_bus=b1, to_bus=b2, length_km=0.1, std_type=\"test_type\", name=\"test_line\")\n",
    "print(net.line.loc[lid])"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Local Standard Type Libraries"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Standard tpyes are saved with the network if you use the pp.to_json function and are therefore still available if you load the network again.\n",
    "\n",
    "If you have a set of standard types that you want to save locally and apply to multiple networks, you can create a set of standard type parameters as a dictionary in the style {\"std_type1: {\"r_ohm_per_km\": r_ohm_per_km,...}, \"std_type2\": {\"r_ohm_per_km\": r_ohm_per_km,...},...} and add it to the network with the create_std_types function:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 7,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>alpha</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>q_mm2</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>type</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>NAYY 4x50 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>210.00</td>\n",
       "      <td>0.142</td>\n",
       "      <td>50.0</td>\n",
       "      <td>0.6420</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x120 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>264.00</td>\n",
       "      <td>0.242</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2250</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x150 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>261.00</td>\n",
       "      <td>0.270</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2080</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>216.00</td>\n",
       "      <td>0.252</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>273.00</td>\n",
       "      <td>0.362</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.117</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>304.00</td>\n",
       "      <td>0.421</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>315.00</td>\n",
       "      <td>0.249</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>406.00</td>\n",
       "      <td>0.358</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>456.00</td>\n",
       "      <td>0.416</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.105</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>250.00</td>\n",
       "      <td>0.319</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.116</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>230.00</td>\n",
       "      <td>0.283</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.119</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>190.00</td>\n",
       "      <td>0.220</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>360.00</td>\n",
       "      <td>0.315</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>340.00</td>\n",
       "      <td>0.280</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>280.00</td>\n",
       "      <td>0.217</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x120 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>112.00</td>\n",
       "      <td>0.366</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.1530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.166</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x185 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>125.00</td>\n",
       "      <td>0.457</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.0990</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.156</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x240 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>135.00</td>\n",
       "      <td>0.526</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.0750</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x300 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>144.00</td>\n",
       "      <td>0.588</td>\n",
       "      <td>300.0</td>\n",
       "      <td>0.0600</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.144</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15-AL1/3-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.105</td>\n",
       "      <td>16.0</td>\n",
       "      <td>1.8769</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24-AL1/4-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.140</td>\n",
       "      <td>24.0</td>\n",
       "      <td>1.2012</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.335</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>12.20</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.300</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>13.20</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.290</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.10</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.40</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.10</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.323</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.315</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.15</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.382</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.50</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.372</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.30</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.50</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.337</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.320</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.75</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.410</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.80</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.400</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>305-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.20</td>\n",
       "      <td>0.740</td>\n",
       "      <td>305.0</td>\n",
       "      <td>0.0949</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 220.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.285</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 380.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>typ1</th>\n",
       "      <td>NaN</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.400</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0100</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>typ2</th>\n",
       "      <td>NaN</td>\n",
       "      <td>30.00</td>\n",
       "      <td>0.300</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0150</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.010</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                    alpha  c_nf_per_km  max_i_ka  q_mm2  \\\n",
       "NAYY 4x50 SE                      0.00403       210.00     0.142   50.0   \n",
       "NAYY 4x120 SE                     0.00403       264.00     0.242  120.0   \n",
       "NAYY 4x150 SE                     0.00403       261.00     0.270  150.0   \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV       0.00403       216.00     0.252   95.0   \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      0.00403       273.00     0.362  185.0   \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      0.00403       304.00     0.421  240.0   \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV        0.00403       315.00     0.249   95.0   \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       0.00403       406.00     0.358  185.0   \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       0.00403       456.00     0.416  240.0   \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      0.00403       250.00     0.319  150.0   \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      0.00403       230.00     0.283  120.0   \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV       0.00403       190.00     0.220   70.0   \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       0.00403       360.00     0.315  150.0   \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       0.00403       340.00     0.280  120.0   \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV        0.00403       280.00     0.217   70.0   \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  0.00393       112.00     0.366  120.0   \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  0.00393       125.00     0.457  185.0   \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  0.00393       135.00     0.526  240.0   \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  0.00393       144.00     0.588  300.0   \n",
       "15-AL1/3-ST1A 0.4                 0.00403        11.00     0.105   16.0   \n",
       "24-AL1/4-ST1A 0.4                 0.00403        11.25     0.140   24.0   \n",
       "48-AL1/8-ST1A 0.4                 0.00403        12.20     0.210   48.0   \n",
       "94-AL1/15-ST1A 0.4                0.00403        13.20     0.350   94.0   \n",
       "34-AL1/6-ST1A 10.0                0.00403         9.70     0.170   34.0   \n",
       "48-AL1/8-ST1A 10.0                0.00403        10.10     0.210   48.0   \n",
       "70-AL1/11-ST1A 10.0               0.00403        10.40     0.290   70.0   \n",
       "94-AL1/15-ST1A 10.0               0.00403        10.75     0.350   94.0   \n",
       "122-AL1/20-ST1A 10.0              0.00403        11.10     0.410  122.0   \n",
       "149-AL1/24-ST1A 10.0              0.00403        11.25     0.470  149.0   \n",
       "34-AL1/6-ST1A 20.0                0.00403         9.15     0.170   34.0   \n",
       "48-AL1/8-ST1A 20.0                0.00403         9.50     0.210   48.0   \n",
       "70-AL1/11-ST1A 20.0               0.00403         9.70     0.290   70.0   \n",
       "94-AL1/15-ST1A 20.0               0.00403        10.00     0.350   94.0   \n",
       "122-AL1/20-ST1A 20.0              0.00403        10.30     0.410  122.0   \n",
       "149-AL1/24-ST1A 20.0              0.00403        10.50     0.470  149.0   \n",
       "184-AL1/30-ST1A 20.0              0.00403        10.75     0.535  184.0   \n",
       "243-AL1/39-ST1A 20.0              0.00403        11.00     0.645  243.0   \n",
       "149-AL1/24-ST1A 110.0             0.00403         8.75     0.470  149.0   \n",
       "184-AL1/30-ST1A 110.0             0.00403         8.80     0.535  184.0   \n",
       "243-AL1/39-ST1A 110.0             0.00403         9.00     0.645  243.0   \n",
       "305-AL1/39-ST1A 110.0             0.00403         9.20     0.740  305.0   \n",
       "490-AL1/64-ST1A 220.0             0.00403        10.00     0.960  490.0   \n",
       "490-AL1/64-ST1A 380.0             0.00403        11.00     0.960  490.0   \n",
       "typ1                                  NaN        10.00     0.400    NaN   \n",
       "typ2                                  NaN        30.00     0.300    NaN   \n",
       "\n",
       "                                  r_ohm_per_km type  x_ohm_per_km  \n",
       "NAYY 4x50 SE                            0.6420   cs         0.083  \n",
       "NAYY 4x120 SE                           0.2250   cs         0.080  \n",
       "NAYY 4x150 SE                           0.2080   cs         0.080  \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV             0.3130   cs         0.132  \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV            0.1610   cs         0.117  \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV            0.1220   cs         0.112  \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV              0.3130   cs         0.123  \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV             0.1610   cs         0.110  \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV             0.1220   cs         0.105  \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV            0.2060   cs         0.116  \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV            0.2530   cs         0.119  \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV             0.4430   cs         0.132  \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV             0.2060   cs         0.110  \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV             0.2530   cs         0.113  \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV              0.4430   cs         0.123  \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV        0.1530   cs         0.166  \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV        0.0990   cs         0.156  \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV        0.0750   cs         0.149  \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV        0.0600   cs         0.144  \n",
       "15-AL1/3-ST1A 0.4                       1.8769   ol         0.350  \n",
       "24-AL1/4-ST1A 0.4                       1.2012   ol         0.335  \n",
       "48-AL1/8-ST1A 0.4                       0.5939   ol         0.300  \n",
       "94-AL1/15-ST1A 0.4                      0.3060   ol         0.290  \n",
       "34-AL1/6-ST1A 10.0                      0.8342   ol         0.360  \n",
       "48-AL1/8-ST1A 10.0                      0.5939   ol         0.350  \n",
       "70-AL1/11-ST1A 10.0                     0.4132   ol         0.339  \n",
       "94-AL1/15-ST1A 10.0                     0.3060   ol         0.330  \n",
       "122-AL1/20-ST1A 10.0                    0.2376   ol         0.323  \n",
       "149-AL1/24-ST1A 10.0                    0.1940   ol         0.315  \n",
       "34-AL1/6-ST1A 20.0                      0.8342   ol         0.382  \n",
       "48-AL1/8-ST1A 20.0                      0.5939   ol         0.372  \n",
       "70-AL1/11-ST1A 20.0                     0.4132   ol         0.360  \n",
       "94-AL1/15-ST1A 20.0                     0.3060   ol         0.350  \n",
       "122-AL1/20-ST1A 20.0                    0.2376   ol         0.344  \n",
       "149-AL1/24-ST1A 20.0                    0.1940   ol         0.337  \n",
       "184-AL1/30-ST1A 20.0                    0.1571   ol         0.330  \n",
       "243-AL1/39-ST1A 20.0                    0.1188   ol         0.320  \n",
       "149-AL1/24-ST1A 110.0                   0.1940   ol         0.410  \n",
       "184-AL1/30-ST1A 110.0                   0.1571   ol         0.400  \n",
       "243-AL1/39-ST1A 110.0                   0.1188   ol         0.390  \n",
       "305-AL1/39-ST1A 110.0                   0.0949   ol         0.380  \n",
       "490-AL1/64-ST1A 220.0                   0.0590   ol         0.285  \n",
       "490-AL1/64-ST1A 380.0                   0.0590   ol         0.253  \n",
       "typ1                                    0.0100   cs         0.020  \n",
       "typ2                                    0.0150   cs         0.010  "
      ]
     },
     "execution_count": 7,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "net = pp.create_empty_network()\n",
    "linetypes = {\"typ1\": {\"r_ohm_per_km\": 0.01, \"x_ohm_per_km\": 0.02, \"c_nf_per_km\": 10, \"max_i_ka\": 0.4, \"type\": \"cs\"},\n",
    "             \"typ2\": {\"r_ohm_per_km\": 0.015, \"x_ohm_per_km\": 0.01, \"c_nf_per_km\": 30, \"max_i_ka\": 0.3, \"type\": \"cs\"}}\n",
    "pp.create_std_types(net, data=linetypes, element=\"line\")\n",
    "pp.available_std_types(net)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "The linetypes dictionary can be easily saved in a local project folder (e.g. using pickle or jsonpickle) and reloaded once it is needed. \n",
    "\n",
    "Another possibility is to copy the standard type library of an existing network:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 8,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>alpha</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>q_mm2</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>type</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>NAYY 4x50 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>210.00</td>\n",
       "      <td>0.142</td>\n",
       "      <td>50.0</td>\n",
       "      <td>0.6420</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x120 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>264.00</td>\n",
       "      <td>0.242</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2250</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x150 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>261.00</td>\n",
       "      <td>0.270</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2080</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>216.00</td>\n",
       "      <td>0.252</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>273.00</td>\n",
       "      <td>0.362</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.117</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>304.00</td>\n",
       "      <td>0.421</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>315.00</td>\n",
       "      <td>0.249</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>406.00</td>\n",
       "      <td>0.358</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>456.00</td>\n",
       "      <td>0.416</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.105</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>250.00</td>\n",
       "      <td>0.319</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.116</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>230.00</td>\n",
       "      <td>0.283</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.119</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>190.00</td>\n",
       "      <td>0.220</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>360.00</td>\n",
       "      <td>0.315</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>340.00</td>\n",
       "      <td>0.280</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>280.00</td>\n",
       "      <td>0.217</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x120 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>112.00</td>\n",
       "      <td>0.366</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.1530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.166</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x185 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>125.00</td>\n",
       "      <td>0.457</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.0990</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.156</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x240 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>135.00</td>\n",
       "      <td>0.526</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.0750</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x300 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>144.00</td>\n",
       "      <td>0.588</td>\n",
       "      <td>300.0</td>\n",
       "      <td>0.0600</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.144</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15-AL1/3-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.105</td>\n",
       "      <td>16.0</td>\n",
       "      <td>1.8769</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24-AL1/4-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.140</td>\n",
       "      <td>24.0</td>\n",
       "      <td>1.2012</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.335</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>12.20</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.300</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>13.20</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.290</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.10</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.40</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.10</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.323</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.315</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.15</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.382</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.50</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.372</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.30</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.50</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.337</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.320</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.75</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.410</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.80</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.400</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.00</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>305-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.20</td>\n",
       "      <td>0.740</td>\n",
       "      <td>305.0</td>\n",
       "      <td>0.0949</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 220.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.285</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 380.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>typ1</th>\n",
       "      <td>NaN</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.400</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0100</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.020</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>typ2</th>\n",
       "      <td>NaN</td>\n",
       "      <td>30.00</td>\n",
       "      <td>0.300</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0150</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.010</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                    alpha  c_nf_per_km  max_i_ka  q_mm2  \\\n",
       "NAYY 4x50 SE                      0.00403       210.00     0.142   50.0   \n",
       "NAYY 4x120 SE                     0.00403       264.00     0.242  120.0   \n",
       "NAYY 4x150 SE                     0.00403       261.00     0.270  150.0   \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV       0.00403       216.00     0.252   95.0   \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      0.00403       273.00     0.362  185.0   \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      0.00403       304.00     0.421  240.0   \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV        0.00403       315.00     0.249   95.0   \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       0.00403       406.00     0.358  185.0   \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       0.00403       456.00     0.416  240.0   \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      0.00403       250.00     0.319  150.0   \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      0.00403       230.00     0.283  120.0   \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV       0.00403       190.00     0.220   70.0   \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       0.00403       360.00     0.315  150.0   \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       0.00403       340.00     0.280  120.0   \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV        0.00403       280.00     0.217   70.0   \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  0.00393       112.00     0.366  120.0   \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  0.00393       125.00     0.457  185.0   \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  0.00393       135.00     0.526  240.0   \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  0.00393       144.00     0.588  300.0   \n",
       "15-AL1/3-ST1A 0.4                 0.00403        11.00     0.105   16.0   \n",
       "24-AL1/4-ST1A 0.4                 0.00403        11.25     0.140   24.0   \n",
       "48-AL1/8-ST1A 0.4                 0.00403        12.20     0.210   48.0   \n",
       "94-AL1/15-ST1A 0.4                0.00403        13.20     0.350   94.0   \n",
       "34-AL1/6-ST1A 10.0                0.00403         9.70     0.170   34.0   \n",
       "48-AL1/8-ST1A 10.0                0.00403        10.10     0.210   48.0   \n",
       "70-AL1/11-ST1A 10.0               0.00403        10.40     0.290   70.0   \n",
       "94-AL1/15-ST1A 10.0               0.00403        10.75     0.350   94.0   \n",
       "122-AL1/20-ST1A 10.0              0.00403        11.10     0.410  122.0   \n",
       "149-AL1/24-ST1A 10.0              0.00403        11.25     0.470  149.0   \n",
       "34-AL1/6-ST1A 20.0                0.00403         9.15     0.170   34.0   \n",
       "48-AL1/8-ST1A 20.0                0.00403         9.50     0.210   48.0   \n",
       "70-AL1/11-ST1A 20.0               0.00403         9.70     0.290   70.0   \n",
       "94-AL1/15-ST1A 20.0               0.00403        10.00     0.350   94.0   \n",
       "122-AL1/20-ST1A 20.0              0.00403        10.30     0.410  122.0   \n",
       "149-AL1/24-ST1A 20.0              0.00403        10.50     0.470  149.0   \n",
       "184-AL1/30-ST1A 20.0              0.00403        10.75     0.535  184.0   \n",
       "243-AL1/39-ST1A 20.0              0.00403        11.00     0.645  243.0   \n",
       "149-AL1/24-ST1A 110.0             0.00403         8.75     0.470  149.0   \n",
       "184-AL1/30-ST1A 110.0             0.00403         8.80     0.535  184.0   \n",
       "243-AL1/39-ST1A 110.0             0.00403         9.00     0.645  243.0   \n",
       "305-AL1/39-ST1A 110.0             0.00403         9.20     0.740  305.0   \n",
       "490-AL1/64-ST1A 220.0             0.00403        10.00     0.960  490.0   \n",
       "490-AL1/64-ST1A 380.0             0.00403        11.00     0.960  490.0   \n",
       "typ1                                  NaN        10.00     0.400    NaN   \n",
       "typ2                                  NaN        30.00     0.300    NaN   \n",
       "\n",
       "                                  r_ohm_per_km type  x_ohm_per_km  \n",
       "NAYY 4x50 SE                            0.6420   cs         0.083  \n",
       "NAYY 4x120 SE                           0.2250   cs         0.080  \n",
       "NAYY 4x150 SE                           0.2080   cs         0.080  \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV             0.3130   cs         0.132  \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV            0.1610   cs         0.117  \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV            0.1220   cs         0.112  \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV              0.3130   cs         0.123  \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV             0.1610   cs         0.110  \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV             0.1220   cs         0.105  \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV            0.2060   cs         0.116  \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV            0.2530   cs         0.119  \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV             0.4430   cs         0.132  \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV             0.2060   cs         0.110  \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV             0.2530   cs         0.113  \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV              0.4430   cs         0.123  \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV        0.1530   cs         0.166  \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV        0.0990   cs         0.156  \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV        0.0750   cs         0.149  \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV        0.0600   cs         0.144  \n",
       "15-AL1/3-ST1A 0.4                       1.8769   ol         0.350  \n",
       "24-AL1/4-ST1A 0.4                       1.2012   ol         0.335  \n",
       "48-AL1/8-ST1A 0.4                       0.5939   ol         0.300  \n",
       "94-AL1/15-ST1A 0.4                      0.3060   ol         0.290  \n",
       "34-AL1/6-ST1A 10.0                      0.8342   ol         0.360  \n",
       "48-AL1/8-ST1A 10.0                      0.5939   ol         0.350  \n",
       "70-AL1/11-ST1A 10.0                     0.4132   ol         0.339  \n",
       "94-AL1/15-ST1A 10.0                     0.3060   ol         0.330  \n",
       "122-AL1/20-ST1A 10.0                    0.2376   ol         0.323  \n",
       "149-AL1/24-ST1A 10.0                    0.1940   ol         0.315  \n",
       "34-AL1/6-ST1A 20.0                      0.8342   ol         0.382  \n",
       "48-AL1/8-ST1A 20.0                      0.5939   ol         0.372  \n",
       "70-AL1/11-ST1A 20.0                     0.4132   ol         0.360  \n",
       "94-AL1/15-ST1A 20.0                     0.3060   ol         0.350  \n",
       "122-AL1/20-ST1A 20.0                    0.2376   ol         0.344  \n",
       "149-AL1/24-ST1A 20.0                    0.1940   ol         0.337  \n",
       "184-AL1/30-ST1A 20.0                    0.1571   ol         0.330  \n",
       "243-AL1/39-ST1A 20.0                    0.1188   ol         0.320  \n",
       "149-AL1/24-ST1A 110.0                   0.1940   ol         0.410  \n",
       "184-AL1/30-ST1A 110.0                   0.1571   ol         0.400  \n",
       "243-AL1/39-ST1A 110.0                   0.1188   ol         0.390  \n",
       "305-AL1/39-ST1A 110.0                   0.0949   ol         0.380  \n",
       "490-AL1/64-ST1A 220.0                   0.0590   ol         0.285  \n",
       "490-AL1/64-ST1A 380.0                   0.0590   ol         0.253  \n",
       "typ1                                    0.0100   cs         0.020  \n",
       "typ2                                    0.0150   cs         0.010  "
      ]
     },
     "execution_count": 8,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "new_net = pp.create_empty_network()\n",
    "pp.copy_std_types(from_net=net, to_net=new_net, element=\"line\")\n",
    "pp.available_std_types(new_net)"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Add Additional Parameters"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "You can define additional parameters in the standard type library and load them into pandapower. For example, if you want to run a reliability analysis for which you need a hazard rate for each line, you will want to add the hazard rate \"h_per_km\" for your individual standard type:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 9,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>alpha</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>h_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>q_mm2</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>type</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>NAYY 4x50 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>210.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.142</td>\n",
       "      <td>50.0</td>\n",
       "      <td>0.6420</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.083</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x120 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>264.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.242</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2250</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NAYY 4x150 SE</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>261.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.270</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2080</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.080</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>216.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.252</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>273.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.362</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.117</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>304.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.421</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.112</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x95 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>315.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.249</td>\n",
       "      <td>95.0</td>\n",
       "      <td>0.3130</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x185 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>406.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.358</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.1610</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x240 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>456.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.416</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.1220</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.105</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>250.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.319</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.116</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>230.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.283</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.119</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 12/20 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>190.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.220</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.132</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x150 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>360.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.315</td>\n",
       "      <td>150.0</td>\n",
       "      <td>0.2060</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.110</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x120 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>340.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.280</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.2530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.113</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>NA2XS2Y 1x70 RM/25 6/10 kV</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>280.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.217</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4430</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.123</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x120 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>112.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.366</td>\n",
       "      <td>120.0</td>\n",
       "      <td>0.1530</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.166</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x185 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>125.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.457</td>\n",
       "      <td>185.0</td>\n",
       "      <td>0.0990</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.156</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x240 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>135.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.526</td>\n",
       "      <td>240.0</td>\n",
       "      <td>0.0750</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.149</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>N2XS(FL)2Y 1x300 RM/35 64/110 kV</th>\n",
       "      <td>0.00393</td>\n",
       "      <td>144.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.588</td>\n",
       "      <td>300.0</td>\n",
       "      <td>0.0600</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.144</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>15-AL1/3-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.105</td>\n",
       "      <td>16.0</td>\n",
       "      <td>1.8769</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>24-AL1/4-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.140</td>\n",
       "      <td>24.0</td>\n",
       "      <td>1.2012</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.335</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>12.20</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.300</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 0.4</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>13.20</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.290</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.10</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.40</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.339</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.10</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.323</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 10.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.25</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.315</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>34-AL1/6-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.15</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.170</td>\n",
       "      <td>34.0</td>\n",
       "      <td>0.8342</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.382</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>48-AL1/8-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.50</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.210</td>\n",
       "      <td>48.0</td>\n",
       "      <td>0.5939</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.372</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>70-AL1/11-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.70</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.290</td>\n",
       "      <td>70.0</td>\n",
       "      <td>0.4132</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.360</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>94-AL1/15-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.350</td>\n",
       "      <td>94.0</td>\n",
       "      <td>0.3060</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.350</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>122-AL1/20-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.30</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.410</td>\n",
       "      <td>122.0</td>\n",
       "      <td>0.2376</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.344</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.50</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.337</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.75</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.330</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 20.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.320</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>149-AL1/24-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.75</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.470</td>\n",
       "      <td>149.0</td>\n",
       "      <td>0.1940</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.410</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>184-AL1/30-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>8.80</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.535</td>\n",
       "      <td>184.0</td>\n",
       "      <td>0.1571</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.400</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>243-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.645</td>\n",
       "      <td>243.0</td>\n",
       "      <td>0.1188</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.390</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>305-AL1/39-ST1A 110.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>9.20</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.740</td>\n",
       "      <td>305.0</td>\n",
       "      <td>0.0949</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.380</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 220.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>10.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.285</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>490-AL1/64-ST1A 380.0</th>\n",
       "      <td>0.00403</td>\n",
       "      <td>11.00</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.960</td>\n",
       "      <td>490.0</td>\n",
       "      <td>0.0590</td>\n",
       "      <td>ol</td>\n",
       "      <td>0.253</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>test_type</th>\n",
       "      <td>NaN</td>\n",
       "      <td>10.00</td>\n",
       "      <td>0.01</td>\n",
       "      <td>0.400</td>\n",
       "      <td>NaN</td>\n",
       "      <td>0.0100</td>\n",
       "      <td>cs</td>\n",
       "      <td>0.020</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "                                    alpha  c_nf_per_km  h_per_km  max_i_ka  \\\n",
       "NAYY 4x50 SE                      0.00403       210.00       NaN     0.142   \n",
       "NAYY 4x120 SE                     0.00403       264.00       NaN     0.242   \n",
       "NAYY 4x150 SE                     0.00403       261.00       NaN     0.270   \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV       0.00403       216.00       NaN     0.252   \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      0.00403       273.00       NaN     0.362   \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      0.00403       304.00       NaN     0.421   \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV        0.00403       315.00       NaN     0.249   \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       0.00403       406.00       NaN     0.358   \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       0.00403       456.00       NaN     0.416   \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      0.00403       250.00       NaN     0.319   \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      0.00403       230.00       NaN     0.283   \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV       0.00403       190.00       NaN     0.220   \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       0.00403       360.00       NaN     0.315   \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       0.00403       340.00       NaN     0.280   \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV        0.00403       280.00       NaN     0.217   \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  0.00393       112.00       NaN     0.366   \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  0.00393       125.00       NaN     0.457   \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  0.00393       135.00       NaN     0.526   \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  0.00393       144.00       NaN     0.588   \n",
       "15-AL1/3-ST1A 0.4                 0.00403        11.00       NaN     0.105   \n",
       "24-AL1/4-ST1A 0.4                 0.00403        11.25       NaN     0.140   \n",
       "48-AL1/8-ST1A 0.4                 0.00403        12.20       NaN     0.210   \n",
       "94-AL1/15-ST1A 0.4                0.00403        13.20       NaN     0.350   \n",
       "34-AL1/6-ST1A 10.0                0.00403         9.70       NaN     0.170   \n",
       "48-AL1/8-ST1A 10.0                0.00403        10.10       NaN     0.210   \n",
       "70-AL1/11-ST1A 10.0               0.00403        10.40       NaN     0.290   \n",
       "94-AL1/15-ST1A 10.0               0.00403        10.75       NaN     0.350   \n",
       "122-AL1/20-ST1A 10.0              0.00403        11.10       NaN     0.410   \n",
       "149-AL1/24-ST1A 10.0              0.00403        11.25       NaN     0.470   \n",
       "34-AL1/6-ST1A 20.0                0.00403         9.15       NaN     0.170   \n",
       "48-AL1/8-ST1A 20.0                0.00403         9.50       NaN     0.210   \n",
       "70-AL1/11-ST1A 20.0               0.00403         9.70       NaN     0.290   \n",
       "94-AL1/15-ST1A 20.0               0.00403        10.00       NaN     0.350   \n",
       "122-AL1/20-ST1A 20.0              0.00403        10.30       NaN     0.410   \n",
       "149-AL1/24-ST1A 20.0              0.00403        10.50       NaN     0.470   \n",
       "184-AL1/30-ST1A 20.0              0.00403        10.75       NaN     0.535   \n",
       "243-AL1/39-ST1A 20.0              0.00403        11.00       NaN     0.645   \n",
       "149-AL1/24-ST1A 110.0             0.00403         8.75       NaN     0.470   \n",
       "184-AL1/30-ST1A 110.0             0.00403         8.80       NaN     0.535   \n",
       "243-AL1/39-ST1A 110.0             0.00403         9.00       NaN     0.645   \n",
       "305-AL1/39-ST1A 110.0             0.00403         9.20       NaN     0.740   \n",
       "490-AL1/64-ST1A 220.0             0.00403        10.00       NaN     0.960   \n",
       "490-AL1/64-ST1A 380.0             0.00403        11.00       NaN     0.960   \n",
       "test_type                             NaN        10.00      0.01     0.400   \n",
       "\n",
       "                                  q_mm2  r_ohm_per_km type  x_ohm_per_km  \n",
       "NAYY 4x50 SE                       50.0        0.6420   cs         0.083  \n",
       "NAYY 4x120 SE                     120.0        0.2250   cs         0.080  \n",
       "NAYY 4x150 SE                     150.0        0.2080   cs         0.080  \n",
       "NA2XS2Y 1x95 RM/25 12/20 kV        95.0        0.3130   cs         0.132  \n",
       "NA2XS2Y 1x185 RM/25 12/20 kV      185.0        0.1610   cs         0.117  \n",
       "NA2XS2Y 1x240 RM/25 12/20 kV      240.0        0.1220   cs         0.112  \n",
       "NA2XS2Y 1x95 RM/25 6/10 kV         95.0        0.3130   cs         0.123  \n",
       "NA2XS2Y 1x185 RM/25 6/10 kV       185.0        0.1610   cs         0.110  \n",
       "NA2XS2Y 1x240 RM/25 6/10 kV       240.0        0.1220   cs         0.105  \n",
       "NA2XS2Y 1x150 RM/25 12/20 kV      150.0        0.2060   cs         0.116  \n",
       "NA2XS2Y 1x120 RM/25 12/20 kV      120.0        0.2530   cs         0.119  \n",
       "NA2XS2Y 1x70 RM/25 12/20 kV        70.0        0.4430   cs         0.132  \n",
       "NA2XS2Y 1x150 RM/25 6/10 kV       150.0        0.2060   cs         0.110  \n",
       "NA2XS2Y 1x120 RM/25 6/10 kV       120.0        0.2530   cs         0.113  \n",
       "NA2XS2Y 1x70 RM/25 6/10 kV         70.0        0.4430   cs         0.123  \n",
       "N2XS(FL)2Y 1x120 RM/35 64/110 kV  120.0        0.1530   cs         0.166  \n",
       "N2XS(FL)2Y 1x185 RM/35 64/110 kV  185.0        0.0990   cs         0.156  \n",
       "N2XS(FL)2Y 1x240 RM/35 64/110 kV  240.0        0.0750   cs         0.149  \n",
       "N2XS(FL)2Y 1x300 RM/35 64/110 kV  300.0        0.0600   cs         0.144  \n",
       "15-AL1/3-ST1A 0.4                  16.0        1.8769   ol         0.350  \n",
       "24-AL1/4-ST1A 0.4                  24.0        1.2012   ol         0.335  \n",
       "48-AL1/8-ST1A 0.4                  48.0        0.5939   ol         0.300  \n",
       "94-AL1/15-ST1A 0.4                 94.0        0.3060   ol         0.290  \n",
       "34-AL1/6-ST1A 10.0                 34.0        0.8342   ol         0.360  \n",
       "48-AL1/8-ST1A 10.0                 48.0        0.5939   ol         0.350  \n",
       "70-AL1/11-ST1A 10.0                70.0        0.4132   ol         0.339  \n",
       "94-AL1/15-ST1A 10.0                94.0        0.3060   ol         0.330  \n",
       "122-AL1/20-ST1A 10.0              122.0        0.2376   ol         0.323  \n",
       "149-AL1/24-ST1A 10.0              149.0        0.1940   ol         0.315  \n",
       "34-AL1/6-ST1A 20.0                 34.0        0.8342   ol         0.382  \n",
       "48-AL1/8-ST1A 20.0                 48.0        0.5939   ol         0.372  \n",
       "70-AL1/11-ST1A 20.0                70.0        0.4132   ol         0.360  \n",
       "94-AL1/15-ST1A 20.0                94.0        0.3060   ol         0.350  \n",
       "122-AL1/20-ST1A 20.0              122.0        0.2376   ol         0.344  \n",
       "149-AL1/24-ST1A 20.0              149.0        0.1940   ol         0.337  \n",
       "184-AL1/30-ST1A 20.0              184.0        0.1571   ol         0.330  \n",
       "243-AL1/39-ST1A 20.0              243.0        0.1188   ol         0.320  \n",
       "149-AL1/24-ST1A 110.0             149.0        0.1940   ol         0.410  \n",
       "184-AL1/30-ST1A 110.0             184.0        0.1571   ol         0.400  \n",
       "243-AL1/39-ST1A 110.0             243.0        0.1188   ol         0.390  \n",
       "305-AL1/39-ST1A 110.0             305.0        0.0949   ol         0.380  \n",
       "490-AL1/64-ST1A 220.0             490.0        0.0590   ol         0.285  \n",
       "490-AL1/64-ST1A 380.0             490.0        0.0590   ol         0.253  \n",
       "test_type                           NaN        0.0100   cs         0.020  "
      ]
     },
     "execution_count": 9,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "import pandapower as pp\n",
    "net = pp.create_empty_network()\n",
    "test_type = {\"r_ohm_per_km\": 0.01, \"x_ohm_per_km\": 0.02, \"c_nf_per_km\": 10, \"max_i_ka\": 0.4, \"type\": \"cs\", \"h_per_km\": 0.01}\n",
    "pp.create_std_type(net, name=\"test_type\", data=test_type, element=\"line\")\n",
    "pp.available_std_types(net, element=\"line\")"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "You can see that the parameter \"h_per_km\" is stored in the standard type database for the new standard type.\n",
    "\n",
    "We now create two lines, one of the new \"test_type\" and one with a standard type that does not have the parameter \"h_per_km\"."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 10,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>std_type</th>\n",
       "      <th>from_bus</th>\n",
       "      <th>to_bus</th>\n",
       "      <th>length_km</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>g_us_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>df</th>\n",
       "      <th>parallel</th>\n",
       "      <th>type</th>\n",
       "      <th>in_service</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>test_line1</td>\n",
       "      <td>test_type</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.010</td>\n",
       "      <td>0.020</td>\n",
       "      <td>10.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.400</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>test_line2</td>\n",
       "      <td>NAYY 4x50 SE</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.642</td>\n",
       "      <td>0.083</td>\n",
       "      <td>210.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.142</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "         name      std_type  from_bus  to_bus  length_km  r_ohm_per_km  \\\n",
       "0  test_line1     test_type         0       1        0.1         0.010   \n",
       "1  test_line2  NAYY 4x50 SE         0       1        0.1         0.642   \n",
       "\n",
       "   x_ohm_per_km  c_nf_per_km  g_us_per_km  max_i_ka   df  parallel type  \\\n",
       "0         0.020         10.0          0.0     0.400  1.0         1   cs   \n",
       "1         0.083        210.0          0.0     0.142  1.0         1   cs   \n",
       "\n",
       "   in_service  \n",
       "0        True  \n",
       "1        True  "
      ]
     },
     "execution_count": 10,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "b1 = pp.create_bus(net, vn_kv=.4)\n",
    "b2 = pp.create_bus(net, vn_kv=.4)\n",
    "l1 = pp.create_line(net, from_bus=b1, to_bus=b2, length_km=0.1, std_type=\"test_type\", name=\"test_line1\")\n",
    "l2 = pp.create_line(net, from_bus=b1, to_bus=b2, length_km=0.1, std_type=\"NAYY 4x50 SE\", name=\"test_line2\")\n",
    "net.line"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "The parameter \"h_per_km\" ist not in the line table, since it is not a pandapower standard parameter. You can however load the parameter from the database with the parameter_from_std_type function:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 11,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>std_type</th>\n",
       "      <th>from_bus</th>\n",
       "      <th>to_bus</th>\n",
       "      <th>length_km</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>g_us_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>df</th>\n",
       "      <th>parallel</th>\n",
       "      <th>type</th>\n",
       "      <th>in_service</th>\n",
       "      <th>h_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>test_line1</td>\n",
       "      <td>test_type</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.010</td>\n",
       "      <td>0.020</td>\n",
       "      <td>10.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.400</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "      <td>0.01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>test_line2</td>\n",
       "      <td>NAYY 4x50 SE</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.642</td>\n",
       "      <td>0.083</td>\n",
       "      <td>210.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.142</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "      <td>None</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "         name      std_type  from_bus  to_bus  length_km  r_ohm_per_km  \\\n",
       "0  test_line1     test_type         0       1        0.1         0.010   \n",
       "1  test_line2  NAYY 4x50 SE         0       1        0.1         0.642   \n",
       "\n",
       "   x_ohm_per_km  c_nf_per_km  g_us_per_km  max_i_ka   df  parallel type  \\\n",
       "0         0.020         10.0          0.0     0.400  1.0         1   cs   \n",
       "1         0.083        210.0          0.0     0.142  1.0         1   cs   \n",
       "\n",
       "   in_service h_per_km  \n",
       "0        True     0.01  \n",
       "1        True     None  "
      ]
     },
     "execution_count": 11,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pp.parameter_from_std_type(net, parameter=\"h_per_km\")\n",
    "net.line"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "Pandapower adds the parameter to the linetable where it is available. The second line does not have a value for h_per_km, since it is not specified in the standard type database. You can however define a fallback (fill) value for lines that do not have a standard type or that have a standard type for which the desired parameter is not available:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 12,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>std_type</th>\n",
       "      <th>from_bus</th>\n",
       "      <th>to_bus</th>\n",
       "      <th>length_km</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>g_us_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>df</th>\n",
       "      <th>parallel</th>\n",
       "      <th>type</th>\n",
       "      <th>in_service</th>\n",
       "      <th>h_per_km</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>test_line1</td>\n",
       "      <td>test_type</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.010</td>\n",
       "      <td>0.020</td>\n",
       "      <td>10.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.400</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "      <td>0.01</td>\n",
       "    </tr>\n",
       "    <tr>\n",
       "      <th>1</th>\n",
       "      <td>test_line2</td>\n",
       "      <td>NAYY 4x50 SE</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.642</td>\n",
       "      <td>0.083</td>\n",
       "      <td>210.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.142</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "      <td>0.02</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "         name      std_type  from_bus  to_bus  length_km  r_ohm_per_km  \\\n",
       "0  test_line1     test_type         0       1        0.1         0.010   \n",
       "1  test_line2  NAYY 4x50 SE         0       1        0.1         0.642   \n",
       "\n",
       "   x_ohm_per_km  c_nf_per_km  g_us_per_km  max_i_ka   df  parallel type  \\\n",
       "0         0.020         10.0          0.0     0.400  1.0         1   cs   \n",
       "1         0.083        210.0          0.0     0.142  1.0         1   cs   \n",
       "\n",
       "   in_service h_per_km  \n",
       "0        True     0.01  \n",
       "1        True     0.02  "
      ]
     },
     "execution_count": 12,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pp.parameter_from_std_type(net, parameter=\"h_per_km\", fill=0.02)\n",
    "net.line"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Change Standard Type"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "The change_std_type function allows changing the standard type of an element."
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 13,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>std_type</th>\n",
       "      <th>from_bus</th>\n",
       "      <th>to_bus</th>\n",
       "      <th>length_km</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>g_us_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>df</th>\n",
       "      <th>parallel</th>\n",
       "      <th>type</th>\n",
       "      <th>in_service</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>test_line</td>\n",
       "      <td>NAYY 4x50 SE</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.642</td>\n",
       "      <td>0.083</td>\n",
       "      <td>210.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.142</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "        name      std_type  from_bus  to_bus  length_km  r_ohm_per_km  \\\n",
       "0  test_line  NAYY 4x50 SE         0       1        0.1         0.642   \n",
       "\n",
       "   x_ohm_per_km  c_nf_per_km  g_us_per_km  max_i_ka   df  parallel type  \\\n",
       "0         0.083        210.0          0.0     0.142  1.0         1   cs   \n",
       "\n",
       "   in_service  \n",
       "0        True  "
      ]
     },
     "execution_count": 13,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "net = pp.create_empty_network()\n",
    "b1 = pp.create_bus(net, vn_kv=.4)\n",
    "b2 = pp.create_bus(net, vn_kv=.4)\n",
    "l2 = pp.create_line(net, from_bus=b1, to_bus=b2, length_km=0.1, std_type=\"NAYY 4x50 SE\", name=\"test_line\")\n",
    "net.line"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 14,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/html": [
       "<div>\n",
       "<style scoped>\n",
       "    .dataframe tbody tr th:only-of-type {\n",
       "        vertical-align: middle;\n",
       "    }\n",
       "\n",
       "    .dataframe tbody tr th {\n",
       "        vertical-align: top;\n",
       "    }\n",
       "\n",
       "    .dataframe thead th {\n",
       "        text-align: right;\n",
       "    }\n",
       "</style>\n",
       "<table border=\"1\" class=\"dataframe\">\n",
       "  <thead>\n",
       "    <tr style=\"text-align: right;\">\n",
       "      <th></th>\n",
       "      <th>name</th>\n",
       "      <th>std_type</th>\n",
       "      <th>from_bus</th>\n",
       "      <th>to_bus</th>\n",
       "      <th>length_km</th>\n",
       "      <th>r_ohm_per_km</th>\n",
       "      <th>x_ohm_per_km</th>\n",
       "      <th>c_nf_per_km</th>\n",
       "      <th>g_us_per_km</th>\n",
       "      <th>max_i_ka</th>\n",
       "      <th>df</th>\n",
       "      <th>parallel</th>\n",
       "      <th>type</th>\n",
       "      <th>in_service</th>\n",
       "    </tr>\n",
       "  </thead>\n",
       "  <tbody>\n",
       "    <tr>\n",
       "      <th>0</th>\n",
       "      <td>test_line</td>\n",
       "      <td>NAYY 4x150 SE</td>\n",
       "      <td>0</td>\n",
       "      <td>1</td>\n",
       "      <td>0.1</td>\n",
       "      <td>0.208</td>\n",
       "      <td>0.08</td>\n",
       "      <td>261.0</td>\n",
       "      <td>0.0</td>\n",
       "      <td>0.27</td>\n",
       "      <td>1.0</td>\n",
       "      <td>1</td>\n",
       "      <td>cs</td>\n",
       "      <td>True</td>\n",
       "    </tr>\n",
       "  </tbody>\n",
       "</table>\n",
       "</div>"
      ],
      "text/plain": [
       "        name       std_type  from_bus  to_bus  length_km  r_ohm_per_km  \\\n",
       "0  test_line  NAYY 4x150 SE         0       1        0.1         0.208   \n",
       "\n",
       "   x_ohm_per_km  c_nf_per_km  g_us_per_km  max_i_ka   df  parallel type  \\\n",
       "0          0.08        261.0          0.0      0.27  1.0         1   cs   \n",
       "\n",
       "   in_service  \n",
       "0        True  "
      ]
     },
     "execution_count": 14,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pp.change_std_type(net, l2, \"NAYY 4x150 SE\", element=\"line\")\n",
    "net.line"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {},
   "source": [
    "## Find Standard Type"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "It is possible to search for a standard type given a set of parameters:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 15,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['243-AL1/39-ST1A 110.0']"
      ]
     },
     "execution_count": 15,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pp.find_std_type_by_parameter(net, data={\"r_ohm_per_km\": 0.1188, \"x_ohm_per_km\": 0.39})"
   ]
  },
  {
   "cell_type": "markdown",
   "metadata": {
    "collapsed": true
   },
   "source": [
    "You can also define a tolerance epsilon to find types with similar parameters:"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 16,
   "metadata": {},
   "outputs": [
    {
     "data": {
      "text/plain": [
       "['184-AL1/30-ST1A 110.0', '243-AL1/39-ST1A 110.0', '305-AL1/39-ST1A 110.0']"
      ]
     },
     "execution_count": 16,
     "metadata": {},
     "output_type": "execute_result"
    }
   ],
   "source": [
    "pp.find_std_type_by_parameter(net, data={\"r_ohm_per_km\": 0.12, \"x_ohm_per_km\": 0.40}, epsilon=.05)"
   ]
  }
 ],
 "metadata": {
  "anaconda-cloud": {},
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.6.5"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 1
}
